//
//  APPMessage.swift
//  AESOLAR_IOS
//
//  Created by Mr.Wang on 2019/10/21.
//  Copyright © 2019 Mr.Wang. All rights reserved.
//

import RxCocoa

struct APPMessage {
    
    static let shared = APPMessage()
    
    let unreadMessageCount = BehaviorRelay<Int>.init(value: 0)
    
    func add(_ num: Int) {
        unreadMessageCount.accept(unreadMessageCount.value + num)
    }
    
    func addOne() {
        unreadMessageCount.accept(unreadMessageCount.value + 1)
    }
}
